#include "server.h"

int main(int argc, char *argv[])
{
    if (argc != 2)
    {
        cerr << "erro input,please in:xxx port" << endl;
        exit(-1);
    }

    uint16_t port = stoi(argv[1]);

    unique_ptr<Tcp> tsv = make_unique<Tcp>(port);

    tsv->Creat_socket();
    tsv->Bind();
    tsv->Listen();
    tsv->Run();

    return 0;
}